SELECT p.iPostID, p.iPostType, p.iAdType, p.iUserType, p.strTitle, p.iSubType, p.iItemType, p.iPrice, p.iPriceUnit, json_unquote(p.jsonLocation->"$.city") AS city, p.jsonExtra, p.tmPosted, p.iShowImg, p.strImages, p.strVideos, p.strPostURL FROM posts p WHERE p.iActive=1 AND p.iPostType=2 AND iPostID IN (SELECT t.iPostID FROM posttext t WHERE t.iDomID=1 AND MATCH (t.strSearch) AGAINST ('+how +cars +were +invented' IN BOOLEAN MODE)) AND iCityID IN (2267,2396,2411,2447,2366,2474,2230,2299,2297,2276,4316,2298,2268,2324,2351,2463,4456,23,2263,2269,4482,4323,2282,2454,2290,4483,2288,24,2442,4337,4343,4314,4355,4362,4488,4347,4410,4448,4301,4424,2296,4350,2432,4407,4282,4490,4449,4334,2334,4313,4526,4472,4328,2319,4329,4399,4536,4492,4369,4429,4408,2215,4331,4428,4480,4395,2403,4505,4385,2300,4534,4502,4533,4452,4503,2245,4300,4437,4453,4416,4368,4341,2257,4425,4421,4360,2457,4430,4333,4486,4364,4418,4319,4500,4349,4467,4468,2465,4445,4335,4283,4434,4491,4326,4376,4432,4478,4289,1953,4403,4344,4291,1942,1934,4391,4404,2461,4524,1995,4374,1892,15,4363,2271,4412,4372,4387,4443,4294,4529,4496,4423,4508,4427,2279,4392,4413,2466,2292,1918,4420,4380,2476,4299,4431,4460,2014,1963,2221,4353,4499,1895,4358,4309,2240,4348,2019,4516,4359,4307,2018,4406,4417,1884,4346,2408,4311,1984,4475,4519,16621,4531,1954,4292,2253,4386,4518,4426,2387,4336,4440,4446,4532,4332,4458,4377,2273,4290,4327,4281) ORDER BY FIELD(iCityID, 2267,2396,2411,2447,2366,2474,2230,2299,2297,2276,4316,2298,2268,2324,2351,2463,4456,23,2263,2269,4482,4323,2282,2454,2290,4483,2288,24,2442,4337,4343,4314,4355,4362,4488,4347,4410,4448,4301,4424,2296,4350,2432,4407,4282,4490,4449,4334,2334,4313,4526,4472,4328,2319,4329,4399,4536,4492,4369,4429,4408,2215,4331,4428,4480,4395,2403,4505,4385,2300,4534,4502,4533,4452,4503,2245,4300,4437,4453,4416,4368,4341,2257,4425,4421,4360,2457,4430,4333,4486,4364,4418,4319,4500,4349,4467,4468,2465,4445,4335,4283,4434,4491,4326,4376,4432,4478,4289,1953,4403,4344,4291,1942,1934,4391,4404,2461,4524,1995,4374,1892,15,4363,2271,4412,4372,4387,4443,4294,4529,4496,4423,4508,4427,2279,4392,4413,2466,2292,1918,4420,4380,2476,4299,4431,4460,2014,1963,2221,4353,4499,1895,4358,4309,2240,4348,2019,4516,4359,4307,2018,4406,4417,1884,4346,2408,4311,1984,4475,4519,16621,4531,1954,4292,2253,4386,4518,4426,2387,4336,4440,4446,4532,4332,4458,4377,2273,4290,4327,4281) ASC, p.tmPosted DESC LIMIT 24